﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using EntitiesTM;
using Business;

namespace TimeWork.masterpage
{
    public partial class Home : System.Web.UI.MasterPage
    {
        protected void Page_Load(object sender, EventArgs e)
        {
            if (Session["email"] != null)
            {
                EnStaff staff = BuStaff.GetStaffByEmailOpt(Session["email"].ToString(),Session["companyid"].ToString());
                LoginBox.StaffExist = staff;
                TopMenu.StaffExist = staff;
            }
            else
            {
                Response.Redirect("~/Login.aspx");
            }
        }
    }
}